import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
export default new Vuex.Store({
  strict: true,
  state: {
    is: '',
    show: false,
    ind: '',
  },
  mutations: {
    SET_IS(state, obj) {
      if (state.ind === obj.i) {
        state.show = !state.show
      } else {
        state.ind = obj.i
        state.is = obj.name
        state.show = true
      }
    },
  },
})
